package dao;

import java.sql.Connection;
import java.sql.DriverManager;

public class Database {

	public Connection getConnection() throws Exception {
		
		String DB_URL = "jdbc:mysql://131.94.130.56:3306/cube?useUnicode=true&characterEncoding=utf8";
		try {
			Connection conn = null;
			Class.forName("com.mysql.jdbc.Driver");
			conn = DriverManager.getConnection(DB_URL,"root","5200tt00");
			if(conn==null){
				System.out.println("Conn Error");
			}
			return conn;
		} catch (Exception e) {
			// TODO: handle exception
			e.printStackTrace();
		}
		return null;
	}
}
